<!-- inc:header -->
<div class="notice"><div class="p">
	<table width="100%" cellpadding="0" cellspacing="0">
	<tr>
		<td><span class="lead">&nbsp;&raquo; 添加/修改模块</span></td>
		<td align="right"><a href="{:site_url('ctrl')}" class="button">返回模块列表</a></td>
	</tr>
	</table>
</div></div>
<form method="post" action="{:site_url('ctrl,setok')}id={:$id}" onsubmit="return chk('{:$id}');">
<div class="table">
	<div class="left"><span class="red">*</span> 模块名：</div>
	<input type="text" id="title" name="title" value="{:$rs[title]}" />
</div>
<div class="table">
	<div class="left"><span class="red">*</span> 所属模块组：</div>
	<select name="group_id" id="group_id">
	<option value="0">全部组</option>
	<!-- $group_list AS $key=>$value -->
	<!-- if(!$value[js_function]) -->
	<option value="{:$value[id]}"{if($rs[group_id] == $value[id])} selected{end}>{:$value[title]}</option>
	<!-- end -->
	<!-- end -->
	</select>
</div>
<div class="table">
	<div class="left"><span class="red">*</span> 唯一标识：</div>
	<input type="text" id="identifier" name="identifier" value="{:$rs[identifier]}" class="short_input" {if($id)} disabled{end} />
	<span class="clue_on"> 唯一标识不允许为空，仅限<span class="red">小写字母，不要超过8位</span></span>
</div>
<div class="table">
	<div class="left">备注：</div>
	<input type="text" id="note" name="note" value="{:$rs[note]}" class="long_input" />
	<span class="clue_on"> 简单说明这个模块做什么，仅限后台使用</span>
</div>
<!-- if($id) -->
<input type="hidden" id="ctrl_init_list" />
<input type="hidden" id="ctrl_init_user" />
<input type="hidden" id="ctrl_init" value="{:$rs[ctrl_init]}"/>
<div class="table">
	<div class="left">控制层：</div>
	<table cellpadding="0" cellspacing="0">
	<tr>
		<!-- if($rs[ctrl_init] == "list") -->
		<td><input type="text" value="内容管理" disabled /></td>
		<!-- else -->
		<td><input type="text" value="{:$rs[ctrl_init]}" disabled></td>
		<!-- end -->
		<td class="clue_on">&nbsp;控制层不允许再修改</td>
		<td id="ctrl_init_input"></td>
	</tr>
	</table>
</div>
<!-- else -->
<div class="table">
	<div class="left"><span class="red">*</span> 控制层：</div>
	<table cellpadding="0" cellspacing="0">
	<tr>
		<td><input type="radio" name="ctrl_init" value="list" id="ctrl_init_list"  onclick="ctrl_set('list')"></td>
		<td>内容管理&nbsp;</td>
		<td><input type="radio" name="ctrl_init" value="" id="ctrl_init_user" onclick="ctrl_set('user')"></td>
		<td>自定义&nbsp;</td>
		<td id="ctrl_init_input"><input type="text" name="ctrl_init_val" value="{:$rs[ctrl_init]}" class="short_input"></td>
		<td class="clue_on">&nbsp;自定义时请填写app/control/目录下的文件名（不含.php）</td>
	</tr>
	</table>
</div>
<!-- end -->
<div id="content_set">

	<div class="table">
		<div class="left">分类：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_cate" value="1"{if($rs[if_cate])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_cate" value="0"{if(!$rs[if_cate])} checked{end}></td>
			<td>不支持&nbsp; &nbsp; &nbsp; &nbsp;<span style="color:red;">至主题</span></td>
			<td><input type="checkbox" name="cate2sub"{if($rs[cate2sub])} checked{end}></td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">&nbsp;</div>
		<table>
		<tr>
			<td class="clue_on">“至主题”功能适合公司简介、联系我们等单页面信息，分类等同于旧版的单页面分组功能</td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">会员：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_post" value="1"{if($rs[if_post])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_post" value="0"{if(!$rs[if_post])} checked{end}></td>
			<td>不支持&nbsp; &nbsp; &nbsp; &nbsp;<span class="red">免审核</span></td>
			<td><input type="checkbox" name="u_free_check"{if($rs[u_free_check])} checked{end}></td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">游客：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_guest" value="1"{if($rs[if_guest])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_guest" value="0"{if(!$rs[if_guest])} checked{end}></td>
			<td>不支持&nbsp; &nbsp; &nbsp; &nbsp;<span class="red">免审核</span></td>
			<td><input type="checkbox" name="g_free_check"{if($rs[g_free_check])} checked{end}></td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">回复：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_reply" value="1"{if($rs[if_reply])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_reply" value="0"{if(!$rs[if_reply])} checked{end}></td>
			<td>不支持&nbsp; &nbsp; &nbsp; &nbsp;<span class="red">免审核</span></td>
			<td><input type="checkbox" name="r_free_check"{if($rs[r_free_check])} checked{end}></td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">点评：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_hits" value="1"{if($rs[if_hits])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_hits" value="0"{if(!$rs[if_hits])} checked{end}></td>
			<td>不支持&nbsp;</td>
			<td class="clue_on">允许对主题进行好评、差评，<span class="red"> 仅启用此功能，才有点击率功能</span></td>
		</tr>
		</table>
	</div>

	<input type="hidden" id="if_point" name="if_point" value="0" />

	<div class="table">
		<div class="left">前台列表或内容：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="insearch" value="1"{if($rs[insearch])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="insearch" value="0"{if(!$rs[insearch])} checked{end}></td>
			<td>不支持&nbsp;</td>
			<td class="clue_on">启用此功能后才能生成相应的列表页及详细内容页</td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">缩略图：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_thumb" value="1"{if($rs[if_thumb])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_thumb" value="0"{if(!$rs[if_thumb])} checked{end}></td>
			<td>不支持&nbsp; &nbsp; &nbsp; &nbsp;<span style="color:red;">必填</span></td>
			<td><input type="checkbox" name="if_thumb_m"{if($rs[if_thumb_m])} checked{end}></td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">前台默认图片：</div>
		<select name="inpic" id="inpic">
		<option value="">不关联，单独获取</option>
		<!-- $gdlist AS $key=>$value -->
		<option value="{:$value[pictype]}"{if($rs[inpic] == $value[pictype])} selected{end}>关联：{:$value[picsubject]}</option>
		<!-- end -->
		</select>
		<span class="clue_on">&nbsp;不支持缩略图的模块，此参数无效</span>
	</div>

	<div class="table">
		<div class="left">扩展属性：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_propety" value="1"{if($rs[if_propety])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_propety" value="0"{if(!$rs[if_propety])} checked{end}></td>
			<td>不支持&nbsp;</td>
			<td class="clue_on"> 支持将有：置顶、推荐、精华三个属性可选</td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">电子商务：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_biz" value="1"{if($rs[if_biz])} checked{end}></td>
			<td>支持&nbsp;</td>
			<td><input type="radio" name="if_biz" value="0"{if(!$rs[if_biz])} checked{end}></td>
			<td>不支持&nbsp;</td>
			<td class="clue_on">启用此功能，将支持购物车等消费行为</td>
		</tr>
		</table>
	</div>

	<div class="table">
		<div class="left">网址必填：</div>
		<table cellpadding="0" cellspacing="0">
		<tr>
			<td><input type="radio" name="if_url_m" value="1"{if($rs[if_url_m])} checked{end}></td>
			<td>是&nbsp;</td>
			<td><input type="radio" name="if_url_m" value="0"{if(!$rs[if_url_m])} checked{end}></td>
			<td>不是&nbsp;</td>
			<td class="clue_on">这里指的是自定义的链接网址</td>
		</tr>
		</table>
	</div>
</div>



<div class="table">
	<div class="left">权限：</div>
	<table cellpadding="0" cellspacing="0">
	<tr>
		<!-- $popedom_list AS $key=>$value -->
		<td><input type="checkbox" name="popedom[]" value="{:$value[id]}"{if(in_array($value[id],$rs[popedom]))} checked{end}>{:$value[title]} &nbsp;</td>
		<!-- row:5 -->
		<!-- end -->
	</tr>
	</table>
</div>
<div class="table">
	<div class="left">&nbsp;</div>
	<table>
	<tr>
		<td class="clue_on">在这里配置的权限将在管理员中体现，管理员可以根据自己的权限进行设权</td>
	</tr>
	</table>
</div>
<div class="table">
	<div class="left">排序：</div>
	<input type="text" id="taxis" name="taxis" value="{:$rs[taxis] ? $rs[taxis] : '255'}" class="short_input" />
	<span class="clue_on"> 值越小越往前靠</span>
</div>
<div class="table">
	<div class="left">&nbsp;</div>
	<input type="submit" value="提 交" class="submit" />
	<br /><br />
</div>

</form>

<script type="text/javascript">
var ctrl_init = "{:$rs[ctrl_init]}";
ctrl_set(ctrl_init);
</script>

<!-- inc:footer -->